﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;

namespace ClickerClimber
{
    static public class GameParameters
    {
        public const int GAME_WIDTH = 755;
        public const int GAME_HEIGHT = 650;

        //game definitions
        public const int BOARD_BASE_ROWS = 100;
        public const int BOARD_BASE_COLUMNS = 7;

        public const int BOARD_INITIAL_ROWS = 5;
        public const int BOARD_INITIAL_COLUMNS = 7;

        public static Vector2 BASE_BOARD_POSITION = new Vector2(200, 618);
        public static Vector2 SCROLL_OFFSET = new Vector2(0, 0);
        public const int MARGIN_TOP = 200;
        public const int MARGIN_BOTTOM = 350;
        public const float GEM_MASS_1 = 100.0f;
        public const float GEM_MASS_2 = 100.0f;
        public const float GEM_MASS_3 = 100.0f;

        public const int BOARD_CELL_WIDTH = 65;
        public const int BOARD_CELL_HEIGHT = 65;


        public static Vector2 SCORE_OFFSET = new Vector2(20, 0);
        public static Vector2 HIGH_OFFSET = new Vector2(85, 105);
        public static Vector2 TIME_OFFSET = new Vector2(GameParameters.GAME_WIDTH - 180, 0);
        public static Vector2 COUNTDOWN_OFFSET = new Vector2(GameParameters.GAME_WIDTH - 180, 5);


        public const int NUM_ITEMS = 4;

        public const bool BeaverEnabled = true;

        public const int NUM_CREATED_ITEMS_REMOVE3 = 1;
        public const int NUM_CREATED_ITEMS_REMOVE4 = 2;
        public const int NUM_CREATED_ITEMS_REMOVE5 = 3;
        public const int NUM_CREATED_ITEMS_REMOVE6 = 4;
        public const int NUM_CREATED_ITEMS_REMOVE7 = 5;
        public const int NUM_CREATED_ITEMS_REMOVE8 = 6;
        public const int NUM_CREATED_ITEMS_REMOVE9 = 7;
        public const int NUM_CREATED_ITEMS_REMOVE10 = 8;
        public const int NUM_CREATED_ITEMS_REMOVEMAX = 9;

        public const int POINTS_REMOVE3 = 100;
        public const int POINTS_REMOVE4 = 200;
        public const int POINTS_REMOVE5 = 300;
        public const int POINTS_REMOVE6 = 400;
        public const int POINTS_REMOVE7 = 500;
        public const int POINTS_REMOVE8 = 600;
        public const int POINTS_REMOVE9 = 700;
        public const int POINTS_REMOVE10 = 800;
        public const int POINTS_REMOVEMAX = 900;


        public const int TIME_SPLASH_WAIT = 3;
        
        public const string BOARD_BASE_TEXTURE_NAME = "Textures/header";
        public const string BOARD_FOOTER_TEXTURE_NAME = "Textures/footer";
        public const string BLUE_ITEM_TEXTURE_NAME = "Textures/blue";
        public const string RED_ITEM_TEXTURE_NAME = "Textures/red";
        public const string GREEN_ITEM_TEXTURE_NAME = "Textures/green";
        public const string YELLOW_ITEM_TEXTURE_NAME = "Textures/yellow";
        public const string MAGENTA_ITEM_TEXTURE_NAME = "Textures/magenta";
        public const string BACKGROUND_ITEM1_TEXTURE_NAME = "Textures/block";
        public const string BACKGROUND_ITEM2_TEXTURE_NAME = "Textures/tile2";
        public const string BACKGROUND_ITEM3_TEXTURE_NAME = "Textures/tile3";
        public const string SPLASH_SCREEN_TEXTURE_NAME = "Textures/splash_screen";

        public const string FOOTER_TEXTURE_NAME = "Textures/footer";
        public const string HEADER_TEXTURE_NAME = "Textures/header";

        public const string WATER_1_TEXTURE_NAME = "Textures/ola";
        public const string WATER_2_TEXTURE_NAME = "Textures/ola";

        public const string TREE_1_TEXTURE_NAME = "Textures/tree_1";
        public const string TREE_2_TEXTURE_NAME = "Textures/tree_2";
        public const string TREE_3_TEXTURE_NAME = "Textures/tree_3";

        public const string BEAVER_TEXTURE_NAME = "Textures/castor_bite_1";
        public const string BEAVER_BITE_TEXTURE_NAME = "Textures/Castor_bite/castor_bite_";
        public const string BEAVER_UP_TEXTURE_NAME = "Textures/Castor_up/castor_up_";
        public const string BEAVER_FLY_TEXTURE_NAME = "Textures/Castor_fly/castor_fly_";
        public const string BEAVER_UPR_TEXTURE_NAME = "Textures/Castor_up/castor_upl_";
        public const string BEAVER_DIE_TEXTURE_NAME = "Textures/Castor_die/castor_die_";
        
        public const string BEAVER_OWL_TEXTURE_NAME = "Textures/Flying_owl/flying_owl_";
        public const string BEAVER_OWL_GLASSES_TEXTURE_NAME = "Textures/Flying_owl_glasses/flying_owl_glasses_";
        
        public const int BEAVER_BITE_NB_FRAMES = 8;
        public const int BEAVER_UP_NB_FRAMES = 3;
        public const int BEAVER_DIE_NB_FRAMES = 5;
        public const int BEAVER_FLY_NB_FRAMES = 1;
        public const int BEAVER_OWL_NB_FRAMES = 20;
        public const int BEAVER_OWL_GLASSES_NB_FRAMES = 20;

        public static Vector2 OWL_POSITION = new Vector2(65, 275);

        public const string SCORE_TEXTURE_NAME = "Textures/score";
        public const string TIME_TEXTURE_NAME = "Textures/points";

        public const string JIMBO_TEXTURE_NAME = "Textures/jimbo";
        public const string JIMBO_MOTION_TEXTURE_NAME = "Textures/jimbomotion";

        public const string WIN_1_TEXTURE_NAME = "Textures/jimbow1";
        public const string WIN_2_TEXTURE_NAME = "Textures/jimbow2";

        public const string LOSE_1_TEXTURE_NAME = "Textures/jimbol1";
        public const string LOSE_2_TEXTURE_NAME = "Textures/jimbol2";

        public const string GAME_OVER_TEXTURE_NAME = "Textures/gameover";
        public const string GAME_WIN_TEXTURE_NAME = "Textures/youwin";
        public const string PLAY_BUTTON_TEXTURE_NAME = "Textures/play";

        public const string MUSIC_TITLE = "Sound/titleMusic";
        public const string MUSIC_TITLE2 = "Sound/titleMusic2";
        public const string MUSIC_GAME = "Sound/gameplayMusic";
        public const string MUSIC_WIN = "Sound/gameWin";
        public const string MUSIC_LOSE = "Sound/gameOver";

        public const string SOUND_WOOW_NAME = "Sound/woow_x";

        public const string SOUND_CLEAR_SMALL = "Sound/clearSmall";
        public const string SOUND_CLEAR_MEDIUM = "Sound/clearMedium";
        public const string SOUND_CLEAR_LARGE = "Sound/clearLarge";
        public const string SOUND_INVALID_CLICK = "Sound/invalid";
        public const string SOUND_BLOCK_CREATED = "Sound/blockCreated";
        public const string SOUND_BLOCK_DAMAGED = "Sound/blockDamaged";
        public const string SOUND_BLOCK_DESTROYED = "Sound/blockDestroyed";
        public const string SOUND_ENEMY_KILLED = "Sound/enemyKilled";
        public const string SOUND_ENEMY_APPEARING = "Sound/enemyAppearing";
        public const string SOUND_CHARACTER_CLIMB = "Sound/climbing";
        public const string SOUND_CHARACTER_FALL = "Sound/falling";
        public const string SOUND_LAST_10_SECONDS = "Sound/timerIsEnding";


        public const float MIN_MUSIC_PITCH = -0.5f;
        public const float MAX_MUSIC_PITCH = 0.5f;

        public const int TARGET_HEIGHT = 50;

        public const string SCORE_TEXT = "Score";
        public const string HIGH_TEXT = "High";

        public const int INITIAL_LEVEL_WATER_Y = 500;
        public const int MAX_WATER_TIME = 20;
        public const int MIN_WATER_TIME = 3;

        public const int GAME_TIME = 120; //two minutes(seg) 

        public const float JIMBO_MOTION_TIME = 0.2f;
        public const int WATER_PHASE_1_TIME = 15;
        public const int WATER_PHASE_2_TIME = 50;
        public const int WATER_PHASE_3_TIME = 80;

        public const int WATER_INCREASE_PHASE_1 = GameParameters.BOARD_CELL_HEIGHT / 5;
        public const int WATER_INCREASE_PHASE_2 = GameParameters.BOARD_CELL_HEIGHT / 4;
        public const int WATER_INCREASE_PHASE_3 = GameParameters.BOARD_CELL_HEIGHT / 3;
    }
}
